<include file="common/hearder" />
<div style="margin-top: 20px;">
    <form class="navbar-form navbar-left" style="margin-left: 850px" >
        <div class="form-group">
            <input type="text" name="value" class="form-control" placeholder="{$value ? $value : '请输入日期'}">
        </div>
        <input name="search" class="btn btn-success" type="submit" value="搜索">
        <!--<button name="search" type="submit" class="btn btn-default">搜索</button>-->
    </form>
</div>


<div style="margin-top: 20px">
    <form id="list" class="am-form" action="{:U('del_all',array('status'=>$v['status']))}">
        <table class="table table-bordered">
            <thead>
            <tr>
                <th class="table-id">id</th>
                <th class="table-title">员工姓名</th>
                <th class="table-title">日期</th>
                <th class="table-title">上班时间</th>
                <th class="table-title">下班时间</th>
                <th class="table-title">考勤情况</th>
                <!--<th class="table-title">负责人</th>-->
            </tr>
            </thead>
            <tbody>
            <foreach name="list" item="v" >
                <tr>
                    <td>{$v.ad_id}</td>
                    <td>{$v.stf_name}</td>
                    <td>{$v.ad_data}</td>
                    <td>{$v.ad_startword}</td>
                    <td>{$v.ad_endword}</td>
                    <td>{$v['state']==1?'全勤':($v['state']==2?'迟到':($v['state']==3?'早退':($v['state']==4?'早退+迟到':($v['state']==5?'旷工':'事假'))))}</td>
                    <!--<td>{$v.person}</td>-->
                </tr>
            </foreach>
            </tbody>
        </table>
    </form>
    <div class="pages">
        共 {$count} 条记录
        <div class="show_page">{$show}</div>
    </div>
</div>
<script>
    $('.check_all').on('click',function () {
        if ($(this).prop('checked')){
            $('.check_item').each(function () {
                if ($(this).prop('checked')){
                    $(this).prop('checked',false);
                }else {
                    $(this).prop('checked',true);
                }
            });
        }else {
            $('.check_item').prop('checked',false);
        }
    })
</script>
<style>
    .pages a,.pages span {
        display:inline-block;
        padding:2px 5px;
        margin:0 1px;
        border:1px solid #f0f0f0;
        -webkit-border-radius:3px;
        -moz-border-radius:3px;
        border-radius:3px;
    }
    .pages a,.pages li {
        display:inline-block;
        list-style: none;
        text-decoration:none; color:#58A0D3;
    }
    .pages a.first,.pages a.prev,.pages a.next,.pages a.end{
        margin:0;
    }
    .pages a:hover{
        border-color:#50A8E6;
    }
    .pages span.current{
        background:#50A8E6;
        color:#FFF;
        font-weight:700;
        border-color:#50A8E6;
    }

</style>

<include file="common/footer"/>